package jzqb.dao;

import jzqb.bo.AdminDepartmentBo;
import jzqb.po.AdminDepartmentPo;
import net.sf.json.JSONArray;

import java.io.IOException;
import java.util.List;

public interface AdminDepartmentDao {
    List<AdminDepartmentPo> cutList (AdminDepartmentBo adminDepartmentBo);
    long cutCount (AdminDepartmentBo adminDepartmentBo);

    /**
     * 查询所有部门
     * @return
     */
    List<AdminDepartmentPo> findAllDept();

    /**
     * 根据ID 查询部门
     * @param deptId
     * @return
     */
    List<AdminDepartmentBo> getDeptNameById(String deptId);


    boolean editLeader(AdminDepartmentPo adminDepartmentPo);

    boolean isDepartmentcodeExist(String id);

    boolean addDepartment(AdminDepartmentPo departmentPo, String type);

    boolean deleteDepartment(AdminDepartmentPo departmentPo);

    boolean writeExcelData(JSONArray jsonArray) throws IOException;

    boolean isDptEmpty(AdminDepartmentPo departmentPo);
}
